package com.guw.Swing;



import javax.swing.*;
import java.awt.*;
import java.net.URL;

public class JButtonDemo2 extends JFrame {

    public JButtonDemo2(){
        Container container = this.getContentPane();

        URL url = JButtonDemo2.class.getResource("m11.png");
        Icon icon = new ImageIcon(url);

        //多选框
        JCheckBox jCheckBox1 = new JCheckBox("1");
        JCheckBox jCheckBox2 = new JCheckBox("2");
        JCheckBox jCheckBox3 = new JCheckBox("3");

        container.add(jCheckBox1,BorderLayout.NORTH);
        container.add(jCheckBox2,BorderLayout.SOUTH);
        container.add(jCheckBox3,BorderLayout.WEST);






        this.setVisible(true);
        this.setBounds(100,100,500,600);
        this.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
    }

    public static void main(String[] args) {
        new JButtonDemo2();
    }
}

